<%= error_messages_for 'ticket' %>
<%= hidden_field 'ticket', 'project_id' %>
	<tr>
		<th>Name</th>
		<td><%= text_field 'ticket', 'name' %></td>
		<td></td>
	</tr>
	<tr>
		<th>Priority</th>
		<td><%= select 'ticket', 'priority', Ticket.priorities.collect { |key, value| [key.titleize, value]} %></td>
		<td></td>
	</tr>
	<tr>
			<th>Status</th>
			<td><%= select 'ticket', 'status', @ticket.project.edit_states(current_user).collect { |key, value| [key.titleize, value]} %></td>
			<td></td>
	</tr>
	<tr>
			<th>Type</th>
			<td><%= select 'ticket', 'ticket_type', @ticket.project.categories.collect {  |c| [c.name.titleize, c.id]} %></td>
			<td></td>
	</tr>
	<tr>
			<th>Owner</th>
			<td><%= select 'ticket', 'owner_id',  @ticket.project.members.collect {|u| [u.login, u.id]}, {:include_blank => true} %>	</td>
			<td></td>
	</tr>

		<tr>
			<th>Tag's</th>
			<td><%= text_field_tag 'tag_list', @tag_list %></td>
			<td>
				<div id="project_tags">
					<%= render :partial => '/project/tag_list' %>
				</div>
			</td>
		</tr>

	<tr>
			<th>Time</th>
			<td><%= text_field 'ticket', 'hours' %>	</td>
			<td> (in hours)</td>
	</tr>
	<tr>
			<th>End Date</th>
			<td><%= text_field 'ticket', 'end_date' %></td>
			<td> (yyyy-mm-dd)</td>
	</tr>
	<% if @controller.action_name == 'new' || @controller.action_name == 'create'-%>
	<tr>
		<th>Body</th>
		<td><%= text_area :ticket_reply, 'body' %></td>
		<td>
			<%= some_html_explanation(); %>
		</td>
	</tr>
	<% end -%>
